const { warn } = require("../utils/log_tool");
const { registerSearchInstallLocation } = require("../utils/reg_tool");
const { which } = require("../utils/which_tool");
const { BaseCommand } = require("./base");

class WhichCommand extends BaseCommand {
    async execute() {
        const result = await which(this.selfData.target);
        if (!result) {
            warn(`未找到 ${this.selfData.target}`);
        }
        return result;
    }
}

module.exports = {
    WhichCommand,
};
